package com

import scala.concurrent.duration._

import io.gatling.core.Predef._
import io.gatling.http.Predef._
import io.gatling.jdbc.Predef._

object Chongzhi {


	val headers_0 = Map(
		"Accept" -> "application/json, text/plain, */*",
		"Content-Type" -> "application/json;charset=utf-8",
		"act" -> "2",
		"api-version" -> "5.0",
		"opType" -> "0")

	val headers_2 = Map(
		"Accept" -> "application/json, text/plain, */*",
		"act" -> "2",
		"api-version" -> "5.0",
		"opType" -> "0")

	val headers_3 = Map("Pragma" -> "no-cache")

    val uri2 = "http://detectportal.firefox.com/success.txt"

	val chongzhi = exec(http("request_0")
			.post("/api/borrow/tenderBorrow?_=1519974384776")
			.headers(headers_0)
			.body(RawFileBody("useraccount_0000_request.txt"))
			.resources(http("request_1")
			.get("/dist/images/invest/success.png"),
            http("request_2")
			.get("/api/borrow/borrowInfo?borrowId=2018030100000000000000002377&isPreview=null&_=1519974385326")
			.headers(headers_2),
            http("request_3")
			.get(uri2 + "")
			.headers(headers_3)))

}